package com.kerrykidz.filemanagement.dao.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.kerrykidz.dao.model.LocPerInoutEntity;
import com.kerrykidz.filemanagement.dao.model.UserInOutCombEntity;
import com.kerrykidz.membership.dao.model.CusGuaEntity;
import com.rdp.framework.core.dao.mapper.MyBatisSuperMapper;
import com.rdp.framework.core.model.MyBatisSuperModel;
import com.rdp.framework.exception.RDPException;

@Repository
public interface LocPerInoutEntityMapper extends MyBatisSuperMapper<LocPerInoutEntity> {

	/**
	 * 获取会员进出场纪录
	 * @param memberId
	 * @return
	 */
	public List<UserInOutCombEntity> listVipInOutHis(@Param("memberIdList") List<String> memberIdList);
	
	/**
	 * 获取进出场记录
	 * @return
	 */
	public List<LocPerInoutEntity> getAllPerInOut(MyBatisSuperModel model);
	
	/**
	 * 保存实体
	 * @return
	 */
	public void saveEntity(LocPerInoutEntity entity)throws RDPException;
	
	/**
	 * 更新实体
	 * @return
	 */
	public void updateEntity(LocPerInoutEntity entity)throws RDPException;
	
	/**
	 * 根据会员或监护人ID更新实体
	 */
	public void updateEntityById(@Param("fkMemId") String fkMemId, @Param("fkGuaId") String fkGuaId) throws RDPException;
	
	/**
	 * 获取场内监护人
	 */
	public List<CusGuaEntity> getCusGuaList(@Param("familyId") String familyId) throws RDPException;
	
	/**
	 * 获取场内监护人
	 */
	public List<LocPerInoutEntity> getLocPerInOutByMemId(@Param("memberId") String memberId) throws RDPException;
	
	
	public Integer indexFloorNum()throws RDPException;
	
	/**
	 * 根据批次号查询进场数量
	 */
	public Integer findCountByFambatch(@Param("famBatch") String famBatch) throws RDPException;
}